/*
 ********************************************************************************
 *
 * Copyright (c) 2019-2024 Renesas Electronics Corporation and/or its affiliates
 *
 ********************************************************************************
 */

package com.dialog.suotalib.interfaces.callbacks;

import android.bluetooth.BluetoothDevice;

import com.dialog.suotalib.global.SuotaProfile;

public interface ISuotaScanner {
    /**
     * Gets triggered every time that a non successful start scan request occurs.
     *
     * @param failure reason caused the failure enum
     */
    void onFailure(SuotaProfile.ScanFailure failure);

    /**
     * Gets triggered every time a new bluetooth device is found through scanning.
     *
     * @param bluetoothDevice the bluetooth device found
     * @param rssi            the rssi
     * @param scanRecord      the scan record the device advertises
     */
    void onDeviceScan(BluetoothDevice bluetoothDevice, int rssi, byte[] scanRecord);

    /**
     * Gets triggered every time the scan status changes.
     *
     * @param newStatus the new scan status
     */
    void onScanStatusChange(SuotaProfile.ScanStatus newStatus);
}
